﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Winter.Core.Infrastructure;
using Winter.Core.Service;

namespace Winter.Web.Mvc.Controllers
{
    public class HomeController : Controller
    {
        private readonly IProductManager _productService;
        public HomeController(IProductManager productService)
        {
            this._productService = productService;
        }
        public ActionResult Index()
        {
            ViewBag.Message = "Welcome to ASP.NET MVC!";

            var products = this._productService.GetAll();

            var ps = EngineContext.Current.Resolve<IProductManager>();

            return View();
        }

        public ActionResult About()
        {
            return View();
        }
    }
}
